using Domain.Entities.Enums;
using System;
using System.Collections.Generic;

namespace Domain.Entities
{
    public class User
    {
        private int id;
        private DateTime registerDateTime;
        private DateTime lastActiveDateTime;
        private int posts;
        private UserStatus status;
        private string username;
        private string password;
        private string activationKey;
        private string email;
        private string firstName;
        private string lastName;
        private DateTime birthdate;
        private Gender gender;
        private string location;
        private string websiteUrl;
        private string avatarUrl;
        private string signature;
        private bool bbcodeByDefault;
        private bool emoticonsByDefault;
        private bool displaySignatureByDefault;
        private byte topicsPerPage;
        private byte messagesPerPage;

        private Theme theme;

        private IList<Group> groups;
        private IList<UserForumPermission> userForumPermissions;
        private IList<Bookmark> bookmarks;

        public virtual int Id
        {
            get { return id; }
            internal set { id = value; }
        }

        public virtual DateTime RegisterDateTime
        {
            get { return registerDateTime; }
            internal set { registerDateTime = value; }
        }

        public virtual DateTime LastActiveDateTime
        {
            get { return lastActiveDateTime; }
            internal set { lastActiveDateTime = value; }
        }

        public virtual int Posts
        {
            get { return posts; }
            internal set { posts = value; }
        }

        public virtual UserStatus Status
        {
            get { return status; }
            internal set { status = value; }
        }

        public virtual string Username
        {
            get { return username; }
            internal set { username = value; }
        }

        public virtual string Password
        {
            get { return password; }
            internal set { password = value; }
        }

        public virtual string ActivationKey
        {
            get { return activationKey; }
            internal set { activationKey = value; }
        }

        public virtual string Email
        {
            get { return email; }
            internal set { email = value; }
        }

        public virtual string FirstName
        {
            get { return firstName; }
            internal set { firstName = value; }
        }

        public virtual string LastName
        {
            get { return lastName; }
            internal set { lastName = value; }
        }

        public virtual DateTime Birthdate
        {
            get { return birthdate; }
            internal set { birthdate = value; }
        }

        public virtual Gender Gender
        {
            get { return gender; }
            internal set { gender = value; }
        }

        public virtual string Location
        {
            get { return location; }
            internal set { location = value; }
        }

        public virtual string WebsiteUrl
        {
            get { return websiteUrl; }
            internal set { websiteUrl = value; }
        }

        public virtual string AvatarUrl
        {
            get { return avatarUrl; }
            internal set { avatarUrl = value; }
        }

        public virtual string Signature
        {
            get { return signature; }
            internal set { signature = value; }
        }

        public virtual bool BBCodeByDefault
        {
            get { return bbcodeByDefault; }
            internal set { bbcodeByDefault = value; }
        }

        public virtual bool EmoticonsByDefault
        {
            get { return emoticonsByDefault; }
            internal set { emoticonsByDefault = value; }
        }

        public virtual bool DisplaySignatureByDefault
        {
            get { return displaySignatureByDefault; }
            internal set { displaySignatureByDefault = value; }
        }

        public virtual byte TopicsPerPage
        {
            get { return topicsPerPage; }
            internal set { topicsPerPage = value; }
        }

        public virtual byte MessagesPerPage
        {
            get { return messagesPerPage; }
            internal set { messagesPerPage = value; }
        }

        public virtual Theme Theme
        {
            get { return theme; }
            internal set { theme = value; }
        }

        public virtual IList<Group> Groups
        {
            get { return groups; }
            internal set { groups = value; }
        }

        public virtual IList<UserForumPermission> UserForumPermissions
        {
            get { return userForumPermissions; }
            internal set { userForumPermissions = value; }
        }

        public virtual IList<Bookmark> Bookmarks
        {
            get { return bookmarks; }
            internal set { bookmarks = value; }
        }

        public virtual void AddGroup(Group group)
        {
            groups.Add(group);
        }

        public virtual void RemoveGroup(Group group)
        {
            groups.Remove(group);
        }
    }
}
